﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace SmartConference.Domain
{
    /// <summary>
    /// 用户管理信息
    /// </summary>
    [Table("UserInfo")]
    public class UserInfo:BaseEntity
    {
        /// <summary>
        /// ID编号
        /// </summary>
        [Key]
        [DatabaseGenerated(DatabaseGeneratedOption.None)]
        public long IDNumber { get; set; }
        /// <summary>
        /// 用户账号
        /// </summary>
        public string UserNumber { get; set; }=string.Empty;
        /// <summary>
        /// 手机号
        /// </summary>
        public string PhoneNumber { get; set; } = string.Empty;
        /// <summary>
        /// 用户密码
        /// </summary>
        public string UserPassword { get; set; } = string.Empty;
        /// <summary>
        /// 会员等级
        /// </summary>
        public string MemberLevel { get; set; } = string.Empty;
        /// <summary>
        /// 性别
        /// </summary>
        public int Sex { get; set; } 
        /// <summary>
        /// 生日
        /// </summary>
        public DateTime Birthday { get; set; }
        /// <summary>
        /// 所在城市
        /// </summary>
        public string LiveCity { get; set; } = string.Empty;
        /// <summary>
        /// 职业
        /// </summary>
        public string Occupation { get; set; } = string.Empty;
        /// <summary>
        /// 个性签名
        /// </summary>
        public string PersonalizedDesc { get; set; } = string.Empty;
        /// <summary>
        /// 用户状态
        /// </summary>
        public UserStatus UserStatus { get; set; }
        /// <summary>
        /// 订单记录
        /// </summary>
        public int OrderList { get; set; }
        /// <summary>
        /// 消费金额
        /// </summary>
        public decimal ConsumptionSum { get; set; }
        /// <summary>
        /// 可用积分
        /// </summary>
        public int AvailableIntegral { get; set; }
    }

    public enum UserStatus
    {
        /// <summary>
        /// 启用
        /// </summary>
        Enable = 1,
        /// <summary>
        /// 禁用
        /// </summary>
        Disable = 0
    }
}
